part of flutter_popup;

abstract class Screen {

  static BuildContext? _context;

  static void init(BuildContext context) {
    _context = context;
  }

  static MediaQueryData get mediaQuery => MediaQuery.of(_context!);

  /// screen width
  static double get width => mediaQuery.size.width;

  // /screen height
  static double get height => mediaQuery.size.height;

  /// dp
  static double get scale => mediaQuery.devicePixelRatio;

  /// top
  static double get statusBar => mediaQuery.padding.top;

  /// bottom
  static double get bottomBar => mediaQuery.padding.bottom;
}
